#!/bin/sh
#default Makefile.am
cd res/skin/default/
echo "defaultdir=/opt/lgb-gp-sna/skin/default" > Makefile.am
echo "default_DATA= \\" >> Makefile.am
for i in *.png
do 
    if [ "$i" != "langCN.png" ] ; then
	echo "$i \\" >> Makefile.am
    fi
done
echo "langCN.png" >> Makefile.am
echo "EXTRA_DIST=\${default_DATA}" >> Makefile.am

#background Makefile.am
cd ../background/
echo "backgrounddir=/opt/lgb-gp-sna/skin/background" > Makefile.am
echo "background_DATA = \\" >> Makefile.am

for i in *.jpg
do
echo "$i \\" >> Makefile.am
done

for i in *.png
do
    if [ "$i" != "background.png" ] ; then
	echo "$i \\" >> Makefile.am
    fi
done
echo "background.png" >> Makefile.am
echo "EXTRA_DIST=\${background_DATA}" >> Makefile.am

#conf Makefile.am
cd ../../conf/
echo "confdir=/opt/lgb-gp-sna/conf" > Makefile.am
echo "conf_DATA= \\" >> Makefile.am
for i in *.conf
do
    if [ "$i" != "Strings.conf" ] ; then
        echo "$i \\" >> Makefile.am
    fi
done
echo "Strings.conf" >> Makefile.am
echo "EXTRA_DIST=\${conf_DATA}" >> Makefile.am

#msg Makefile.am
cd ../msg
echo "msgdir=/opt/lgb-gp-sna/msg" > Makefile.am
echo "msg_DATA=\\" >> Makefile.am
for i in *.conf
do
    if [ "$i" != "ModelDouble.conf" ] ;then
	echo "$i \\" >> Makefile.am
    fi
done
echo "ModelDouble.conf" >> Makefile.am
echo "EXTRA_DIST=\${msg_DATA}" >> Makefile.am
exit